<div class="row">
    <div class="col-md-12">
        <div class="block">
            <div class="block-title">
                <h2><strong>Listado de Categorias</strong></h2>
            </div> 
            <div class="table-responsive">
                <table id="categorias" class="table table-vcenter table-condensed table-bordered">
                    <thead>
                        <tr>
                            <th class="text-center">ID</th>
                            <th>Categoria</th>
                            <th class="text-center">Actions</th>
                        </tr>
                    </thead>
                    <tbody>
                        <?php $i=1;?>
                        <?php foreach ($categorias as $cat): ?>
                        <tr>
                            <td class="text-center"><?php echo $i;$i++;?></td>
                            
                            <td><?php echo $cat['Categoria']['nombre'];?></td>  
                            <td class="text-center">
                                <div class="btn-group">
                                   <?php //echo $this->Html->link('<i class="fa fa-pencil"></i>', array('action'=>'editar', $ciu['Ciudade']['id']),array('class'=>'btn btn-xs btn-default'));?>
                                    <a href="<?php echo $this->Html->url(array('action'=>'editar', $cat['Categoria']['id']))?>" data-toggle="tooltip" title="Editar" class="btn btn-xs btn-primary"><i class="fa fa-pencil"></i></a>                                 
                                    <a href="<?php echo $this->Html->url(array('action'=>'eliminar', $cat['Categoria']['id']))?>" data-toggle="tooltip" title="Eliminar" class="btn btn-xs btn-danger"><i class="fa fa-times"></i></a>
                               <?php //echo $this->Html->link('Eliminar', array('action'=>'eliminar', $ciu['Ciudade']['id']));?>
                                </div>
                            </td>
                        </tr>
                        <?php endforeach;?>
                    </tbody>
                </table>
            </div>
        </div>
    </div> 
</div>
<script>
    $(function() {
        TablesDatatables.init();
    });
    $(document).ready(function(){
        $('#categorias').dataTable();
    }
    );
</script>